/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package findthebomb;

import javafx.stage.Stage;
import javafx.scene.Scene;
import javafx.scene.paint.Color;
import javafx.scene.text.Text;
import javafx.scene.control.ProgressBar;
import javafx.scene.layout.HBox;
import javafx.geometry.VPos;
import javafx.scene.control.ProgressIndicator;
import javafx.scene.text.Font;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;

/**
 * @author Islam Hamdi
 */

def width=700;
def height=600;
var startingScene:Scene;
def startBackGround:Image =
    Image{ url:"{__DIR__}Building.jpg";
}

startingScene=Scene{
    width:width
    height:height
    fill: Color.BLACK;
    content:[

    ImageView {
            image:startBackGround;
            x:0
            y:0
            fitWidth:bind startingScene.width
            fitHeight:bind startingScene.height
        },
        HBox {
                layoutX:bind startingScene.width/2-150
                layoutY:bind startingScene.height/2-80
                spacing: 4
                nodeVPos: VPos.CENTER
                content: [
                     Text {
                                font: Font { name: "Verdana" size: 40 }
                                fill: Color.DARKORANGE
                                stroke: Color.DARKRED
                                strokeWidth: 3
                                content: "Loading ..."
                            },
                            ProgressBar {progress:-2}
                            ProgressIndicator {progress: -1}
                        ]
                    }
    ]

}

Stage{
    title:"Find The Bomb"
    fullScreen:true
    scene:bind startingScene;
}
